* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: #000638;
  color: #fff;
  overflow: hidden;
}

.data-screen {
  width: 100vw;
  height: 100vh;
  background: radial-gradient(circle at center, #001666 0%, #000638 100%);
}

/* 头部样式 */
.header {
  position: relative;
  height: 60px;
  padding: 0 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(to right, rgba(0, 246, 255, 0.1), transparent, rgba(0, 246, 255, 0.1));
}

.header::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    rgba(0, 246, 255, 0.5),
    transparent
  );
}

.header .title {
  font-size: 22px;
  background: linear-gradient(to right, #00f6ff, #3e97ff);
  -webkit-background-clip: text;
  color: transparent;
}

.header .time {
  font-size: 14px;
  color: #00f6ff;
}

/* 标题装饰线 */
.header::before,
.header::after {
  content: '';
  position: absolute;
  top: 0;
  width: 30%;
  height: 2px;
  background: linear-gradient(to right, transparent, #00f6ff, transparent);
}

.header::before {
  left: 0;
  transform: skewX(45deg);
}

.header::after {
  right: 0;
  transform: skewX(-45deg);
}

/* 左侧home按钮 */
.home-btn {
  width: 50px;
  height: 50px;
  background: rgba(0, 246, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #00f6ff;
  cursor: pointer;
}

/* 右侧设置按钮 */
.setting-btn {
  width: 50px;
  height: 50px;
  background: rgba(0, 246, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #00f6ff;
  cursor: pointer;
  transition: all 0.3s ease;
}

.setting-btn:hover {
  background: rgba(0, 246, 255, 0.3);
  transform: scale(1.05);
}

.setting-btn .iconfont {
  font-size: 24px;
}

/* 添加图标字体 */
@font-face {
  font-family: 'iconfont';
  src: url('//at.alicdn.com/t/font_2878668_urpiiop5rn.woff2') format('woff2');
}

.iconfont {
  font-family: 'iconfont' !important;
  font-style: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.icon-fullscreen:before {
  content: '\e7ec';
}

.icon-fullscreen-exit:before {
  content: '\e7ed';
}

/* 内容区域 */
.content {
  display: flex;
  padding: 24px 32px;
  height: calc(100vh - 60px);
  gap: 24px;
  overflow: hidden;
}

/* 面板通用样式 */
.panel {
  position: relative;
  background: linear-gradient(to bottom, rgba(0, 246, 255, 0.2), rgba(6, 30, 93, 0.5));
  border: none;
  padding: 20px;
  margin-bottom: 24px;
  clip-path: polygon(
    0 10px, 10px 0,
    calc(100% - 10px) 0, 100% 10px,
    100% calc(100% - 10px), calc(100% - 10px) 100%,
    10px 100%, 0 calc(100% - 10px)
  );
}

/* 面板边框发光效果 */
.panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid rgba(0, 246, 255, 0.3);
  clip-path: polygon(
    0 10px, 10px 0,
    calc(100% - 10px) 0, 100% 10px,
    100% calc(100% - 10px), calc(100% - 10px) 100%,
    10px 100%, 0 calc(100% - 10px)
  );
}

/* 边角装饰 */
.panel::before,
.panel::after,
.panel > *::before,
.panel > *::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  background-color: #00f6ff;
  z-index: 1;
}

/* 左上角 */
.panel::before {
  left: -1px;
  top: -1px;
  border-top: 2px solid #00f6ff;
  border-left: 2px solid #00f6ff;
}

/* 右上角 */
.panel::after {
  right: -1px;
  top: -1px;
  border-top: 2px solid #00f6ff;
  border-right: 2px solid #00f6ff;
}

/* 左下角 */
.panel > *::before {
  left: -1px;
  bottom: -1px;
  border-bottom: 2px solid #00f6ff;
  border-left: 2px solid #00f6ff;
}

/* 右下角 */
.panel > *::after {
  right: -1px;
  bottom: -1px;
  border-bottom: 2px solid #00f6ff;
  border-right: 2px solid #00f6ff;
}

/* 发光效果 */
.panel {
  box-shadow: inset 0 0 30px rgba(0, 246, 255, 0.1);
}

/* 标题装饰 */
.panel-header {
  position: relative;
  padding-left: 20px;
}

.panel-header .line {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 16px;
  background: linear-gradient(to bottom, #00f6ff, rgba(0, 246, 255, 0.3));
  box-shadow: 0 0 5px rgba(0, 246, 255, 0.5);
}

.chart {
  position: relative;
  height: 240px;
  background: rgba(6, 30, 93, 0.2);
  border: 1px solid rgba(0, 246, 255, 0.2);
  margin: 10px 0;
}

/* 左侧面板 */
.left-panel {
  width: 380px;
  display: flex;
  flex-direction: column;
}

/* 左侧面板中的数据聚合部分 */
.left-panel .panel:first-child {
  height: 30%;
}

.left-panel .panel:nth-child(2) {
  height: 35%;
}

.left-panel .panel:last-child {
  height: calc(35% - 32px); /* 减去两个gap的距离 */
}

/* 左侧面板中的人群画像部分 */
.left-panel .panel:last-child {
  height: calc(65% - 16px); /* 减去gap的距离 */
  .chart {
    height: calc(100% - 40px); /* 减去标题的高度 */
  }
}

.data-list .data-item {
  margin-bottom: 30px;
}

.data-item {
  position: relative;
  padding-left: 15px;
}

.data-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  width: 4px;
  height: 4px;
  background: #00f6ff;
  border-radius: 50%;
  transform: translateY(-50%);
  box-shadow: 0 0 5px #00f6ff;
}

.data-item .label {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 4px;
}

.data-item .value {
  font-size: 26px;
  color: #00f6ff;
  margin-bottom: 4px;
}

.progress-bar {
  height: 4px;
  background: rgba(0, 246, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.progress-bar .bar {
  height: 100%;
  background: linear-gradient(to right, #00f6ff, #0061ff);
  box-shadow: 0 0 10px rgba(0, 246, 255, 0.5);
  border-radius: 2px;
}

/* 中间面板 */
.center-panel {
  flex: 1;
  min-width: 600px;
  display: flex;
  flex-direction: column;
  height: 100%; /* 确保高度填满父容器 */
}

/* 地图容器调整 */
.map-wrapper {
  position: relative;
  flex: 1;
  height: calc(100% - 144px);
  min-height: 0;
  margin-bottom: 24px;
}

.map-wrapper .chart {
  height: 100%;
  min-height: 0; /* 允许内容压缩 */
}

.statistics {
  height: 120px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  padding: 24px;
  background: rgba(6, 30, 93, 0.5);
  border: 1px solid rgba(0, 246, 255, 0.2);
  position: relative;
  margin-top: auto;
}

.statistics::before,
.statistics::after,
.statistics > *::before,
.statistics > *::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  background-color: #00f6ff;
  z-index: 1;
}

/* 统计数据边角装饰 */
.statistics::before {
  left: -1px;
  top: -1px;
  border-top: 2px solid #00f6ff;
  border-left: 2px solid #00f6ff;
}

.statistics::after {
  right: -1px;
  top: -1px;
  border-top: 2px solid #00f6ff;
  border-right: 2px solid #00f6ff;
}

.statistics > *::before {
  left: -1px;
  bottom: -1px;
  border-bottom: 2px solid #00f6ff;
  border-left: 2px solid #00f6ff;
}

.statistics > *::after {
  right: -1px;
  bottom: -1px;
  border-bottom: 2px solid #00f6ff;
  border-right: 2px solid #00f6ff;
}

.stat-item {
  position: relative;
  text-align: center;
  padding: 10px;
}

.stat-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(to right, transparent, #00f6ff, transparent);
}

.stat-item .number {
  font-size: 32px;
  background: linear-gradient(to right, #00f6ff, #3e97ff);
  -webkit-background-clip: text;
  color: transparent;
}

.stat-item .label {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
}

/* 右侧面板 */
.right-panel {
  width: 380px;
  display: flex;
  flex-direction: column;
}

/* 右侧面板中的图表容器 */
.right-panel .panel {
  height: calc((100% - 48px) / 3);
  .chart {
    height: calc(100% - 40px); /* 减去标题的高度 */
  }
}

/* 图表基础样式 */
.chart {
  width: 100%;
  background: rgba(6, 30, 93, 0.2);
  border: 1px solid rgba(0, 246, 255, 0.2);
}

/* 动画效果 */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.panel {
  animation: fadeIn 0.5s ease forwards;
}

.panel:nth-child(1) { animation-delay: 0.1s; }
.panel:nth-child(2) { animation-delay: 0.2s; }
.panel:nth-child(3) { animation-delay: 0.3s; } 

/* 人员分布列表样式 */
.user-list {
  height: calc(100% - 48px);
  overflow-y: auto;
  padding-right: 16px;
}

/* 滚动条样式 */
.user-list::-webkit-scrollbar {
  width: 4px;
}

.user-list::-webkit-scrollbar-thumb {
  background: rgba(0, 246, 255, 0.2);
  border-radius: 2px;
}

.user-list::-webkit-scrollbar-track {
  background: rgba(0, 246, 255, 0.1);
}

/* 用户列表项样式 */
.user-item {
  display: flex;
  align-items: center;
  padding: 12px;
  margin-bottom: 16px;
  background: rgba(0, 246, 255, 0.05);
  border: 1px solid rgba(0, 246, 255, 0.1);
  border-radius: 4px;
  transition: all 0.3s ease;
}

.user-item:hover {
  background: rgba(0, 246, 255, 0.1);
  transform: translateX(5px);
}

/* 头像样式 */
.user-item .avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin-right: 12px;
  border: 2px solid rgba(0, 246, 255, 0.3);
}

/* 用户信息样式 */
.user-info {
  flex: 1;
  overflow: hidden;
}

.user-info .name {
  display: block;
  font-size: 14px;
  color: #00f6ff;
  margin-bottom: 4px;
}

.user-info .address {
  display: block;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 添加列表动画效果 */
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.user-item {
  animation: slideIn 0.5s ease forwards;
}

.user-item:nth-child(1) { animation-delay: 0.1s; }
.user-item:nth-child(2) { animation-delay: 0.2s; }
.user-item:nth-child(3) { animation-delay: 0.3s; }
.user-item:nth-child(4) { animation-delay: 0.4s; } 

/* 调整中间面板布局 */
.center-panel {
  flex: 1;
  min-width: 600px;
  display: flex;
  flex-direction: column;
  height: 100%; /* 确保高度填满父容器 */
}

/* 调整左右两侧面板的高度 */
.left-panel,
.right-panel {
  height: 100%;
  overflow: hidden;
}

/* 调整图表容器的高度 */
.chart {
  height: 100%;
  min-height: 0; /* 允许内容压缩 */
}

/* 确保面板内容不会溢出 */
.panel {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.panel-header {
  flex-shrink: 0; /* 防止标题被压缩 */
}

/* 调整统计数据的边框装饰 */
.statistics::before,
.statistics::after,
.statistics > *::before,
.statistics > *::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  background-color: #00f6ff;
  z-index: 1;
}

/* 左上角 */
.statistics::before {
  left: -1px;
  top: -1px;
  border-top: 2px solid #00f6ff;
  border-left: 2px solid #00f6ff;
}

/* 右上角 */
.statistics::after {
  right: -1px;
  top: -1px;
  border-top: 2px solid #00f6ff;
  border-right: 2px solid #00f6ff;
}

/* 左下角 */
.statistics > *::before {
  left: -1px;
  bottom: -1px;
  border-bottom: 2px solid #00f6ff;
  border-left: 2px solid #00f6ff;
}

/* 右下角 */
.statistics > *::after {
  right: -1px;
  bottom: -1px;
  border-bottom: 2px solid #00f6ff;
  border-right: 2px solid #00f6ff;
}

/* 地图全屏按钮样式 */
.map-fullscreen-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 36px;
  height: 36px;
  background: rgba(0, 246, 255, 0.2);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #00f6ff;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.map-fullscreen-btn:hover {
  background: rgba(0, 246, 255, 0.3);
  transform: scale(1.05);
}

.map-fullscreen-btn .iconfont {
  font-size: 20px;
}

/* 地图全屏样式 */
.map-wrapper:fullscreen {
  background: #000638;
  padding: 20px;
}

.map-wrapper:fullscreen .chart {
  height: calc(100vh - 40px); /* 减去padding */
}

/* 兼容 webkit 浏览器 */
.map-wrapper:-webkit-full-screen {
  background: #000638;
  padding: 20px;
}

.map-wrapper:-webkit-full-screen .chart {
  height: calc(100vh - 40px);
}

/* 兼容 moz 浏览器 */
.map-wrapper:-moz-full-screen {
  background: #000638;
  padding: 20px;
}

.map-wrapper:-moz-full-screen .chart {
  height: calc(100vh - 40px);
}

/* 兼容 ms 浏览器 */
.map-wrapper:-ms-fullscreen {
  background: #000638;
  padding: 20px;
}

.map-wrapper:-ms-fullscreen .chart {
  height: calc(100vh - 40px);
}
